/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package za.ac.cput.ExceptionTest.Impl;

import za.ac.cput.ExceptionTest.AccountException;

/**
 *
 * @author Leo
 */
public class AccountExceptionImpl implements AccountException {
    
    private float balance=0;
    private float amount=0;
    
    
     public AccountExceptionImpl() {
     
    }
    public AccountExceptionImpl(float initBalance) {
        balance= initBalance;
        
    }
    @Override
    public void withdraw(){
    balance = balance -amount;
    }
    @Override
    public float getBalance(){
    return balance;    
    }
    @Override
    public void deposit (float amount){
    balance +=amount;
    }
    @Override
   public float testDepositAmntGreaterThanZero() {
       return amount;
    }


}
